import React from 'react';
import { Router, Route, Switch } from 'dva/router';

import RegisterPage from '../pages/register/RegisterPage';
import LoginPage from '../pages/login/LoginPage';

import HomePage from '../pages/home/HomePage';
import StatusPage from '../pages/status/StatusPage';

function RouterConfig({ history }) {

  return (
    <Router history={history}>
      <Switch>
        <Route path="/login" exact component={LoginPage}/>
        <Route path="/register" exact component={RegisterPage}/>
        <Route path="/home" exact component={HomePage} />
      </Switch>
    </Router>
  );
}

export default RouterConfig;
